<?php
// +----------------------------------------------------------------------
// | 闭馆 模型
// +----------------------------------------------------------------------
namespace app\library\model;

use think\Model;

class Close extends Model{
    /**
     * 删除闭馆时间
     * @param array $id 节点ID
     * @return bool
     */
    public function del($ids = '') {
        if (is_array($ids)) {
            $error = '';
            foreach ($ids as $k => $v) {
                $map = [];
                $map['id'] = $v;
                self::where($map)->delete();
            }
            if ($error) {
                $this->error = $error;
                return false;
            }
            return true;
        }
        $this->error = '参数传递错误';
        return false;
    }
}